<script setup>

// import {ref, reactive} from 'vue'
//
// const argName = ref("张三");
// const user = reactive({
//   username: "admin"
// })
// const changeName = () => {
//   if ('张三' === argName.value) {
//     argName.value = '李四';// 通过这种方式赋值
//   } else if ('李四' === argName.value) {
//     argName.value = '张三';// 通过这种方式赋值
//   }
// }
//
// const changeUser = (paramUsername) => {
//   user.username = paramUsername;
// }

const methodA = () => {

  return new Promise((resolve, reject) => {


    console.log('Method A executed');


    resolve();


  });


}


const methodB = () => {


  console.log('Method B executed');


}


const executeMethods = () => {


  methodA().then(methodB);

}
executeMethods();
</script>

<template>
</template>
<style scoped>
</style>